package MapExample;

import java.util.HashMap;
import java.util.Map;

public class CreateMap {
    public static void main(String[] args) {
        Map<Integer,String> map = new HashMap<Integer,String>();
        map.put(1, "one");
        map.put(2, "two");
//        System.out.println(map.get(1));
//        System.out.println(map.get(2));
        for (Map.Entry<Integer,String> entry : map.entrySet()) {
            System.out.println(entry.getKey() + " " + entry.getValue());
        }
    }
}
